<?php
require 'conn.php';

$name = trim($_POST['name']);
$link = $_POST['link'];
$email = $_POST['email'];
$classname = $_POST['classname'];
$info = $_POST['info'];

$query = mysql_query("update links set name = '$name',link = '$link',email = '$email',classname = '$classname',info = '$info' where id=$_GET[id]");
if ($query) {
	$su = 1;
}else {
	$su = 0;
}
header("Location: ../success.php?su=$su");